/*
 * @Descripttion:
 * @version:
 * @Author: sueRimn
 * @Date: 2020-11-21 09:49:52
 * @LastEditors: sueRimn
 * @LastEditTime: 2020-11-23 16:53:49
 */
import request from "@/utils/request";
import store from "@/store/index";

// 夹带k_token
function addK_Token(data) {
    var token = {
        k_token: store.getters.k_token
    };
    Object.assign(data, token);
    return data;
}

/**
 * 获取违规推送
 */
export function getUserHomePage(data) {
    return request({
        url: "/location_url/user/video.User/UserHomePage",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取粉丝
 */
export function getUserFandList(data) {
    return request({
        url: "/location_url/user/video.User/UserFandList",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取关注
 */
export function getUserFollowList(data) {
    return request({
        url: "/location_url/user/video.User/UserFollowList",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取点赞
 */
export function getIsLikeList(data) {
    return request({
        url: "/location_url/user/video.lists/IsLikeList",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取黑名单
 */
export function getUserBlackList(data) {
    return request({
        url: "/location_url/user/video.User/UserBlackList",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 关注
 */
export function saveUserFollowAdd(data) {
    return request({
        url: "/location_url/user/video.User/UserFollowAdd",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 取消关注
 */
export function saveUserFollowDel(data) {
    return request({
        url: "/location_url/user/video.User/UserFollowDel",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 移除黑名单
 */
export function saveBlackDel(data) {
    return request({
        url: "/location_url/user/video.User/BlackDel",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取个人文章
 */
export function getArticleList(data) {
    return request({
        url: "/location_url/user/article.Lists/articleList",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 删除个人文章
 */
export function todelArticle(data) {
    return request({
        url: "/location_url/user/article.Users/delArticle",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取个人视频
 */
export function getVideoList(data) {
    return request({
        url: "/location_url/user/video.Lists/VideoListByOne",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 删除个人视频
 */
export function todelVideo(data) {
    return request({
        url: "/location_url/user/video.Lists/delVideo",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 访问他人主页
 */
export function getUserHomeByFrom(data) {
    return request({
        url: "/location_url/user/video.User/UserHomeByFrom",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 访问他人主页视频
 */
export function getVideoListByForm(data) {
    return request({
        url: "/location_url/user/video.Lists/VideoListByForm",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 拉黑
 */
export function saveBlackAdd(data) {
    return request({
        url: "/location_url/user/video.User/BlackAdd",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 查看拉黑状态
 */
export function getUserBlackState(data) {
    return request({
        url: "/location_url/user/video.User/UserBlackState",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 添加阅读状态
 */
export function saveAddbrowse(data) {
    return request({
        url: "/location_url/user/article.Users/addbrowse",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 添加阅读状态
 */
export function getListsReply(data) {
    return request({
        url: "/location_url/user/article.Users/listsReply",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 文章点赞
 */
export function articleIsLike(data) {
    return request({
        url: "/location_url/user/article.Users/isLike",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 评论取消点赞
 */
export function saveDelReplyLike(data) {
    return request({
        url: "/location_url/user/article.Users/delReplyLike",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 评论点赞
 */
export function saveAddReplyLike(data) {
    return request({
        url: "/location_url/user/article.Users/addReplyLike",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 删除评论
 */
export function toDelReply(data) {
    return request({
        url: "/location_url/user/article.Users/delReply",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 发表评论
 */
export function saveAddReply(data) {
    return request({
        url: "/location_url/user/article.Users/addReply",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取视频评论
 */
export function getVideoListsReply(data) {
    return request({
        url: "/location_url/user/video.Lists/listsReply",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 获取视频点赞
 */
export function saveVideoIsLike(data) {
    return request({
        url: "/location_url/user/video.Lists/isLike",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 视频评论取消点赞
 */
export function saveVideoDelReplyLike(data) {
    return request({
        url: "/location_url/user/video.Lists/delReplyLike",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 视频评论点赞
 */
export function saveVideoAddReplyLike(data) {
    return request({
        url: "/location_url/user/video.Lists/addReplyLike",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 视频发表评论
 */
export function saveVideoAddReply(data) {
    return request({
        url: "/location_url/user/video.Lists/addReply",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}

/**
 * 视频删除评论
 */
export function saveVideodelReply(data) {
    return request({
        url: "/location_url/user/video.Lists/delReply",
        method: "POST",
        headers: {},
        data: addK_Token(data)
    });
}
